package com.netty.netty;

import com.rpc.handler.NettyServiceHandler;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

@Component
public class NettyService  {
    @Autowired
    private NettyServiceHandler nettyServiceHandler;

    @PostConstruct
    public void startNetty() throws InterruptedException {
        nettyServiceHandler.startNetty(5181);
//        nettyServiceHandler.startNetty(5182);
    }

}
